import sbt._
import Keys._

object ReflectiveBuild extends Build {
  lazy val root = Project("reflective", file(".")).settings(
    name := "reflective",
    version := "1.0",
    organization := "com.googlecode.reflective",
    scalaVersion := "2.9.0-1",
    libraryDependencies ++= Seq(
      "com.thoughtworks.paranamer" % "paranamer" % "2.3",
      "org.scalatest" % "scalatest_2.9.0" % "1.6.1" % "test"
    ),
    publishTo <<= (version) { version: String =>
      val nexus = "http://nexus.scala-tools.org/content/repositories/"
      if (version.trim.endsWith("SNAPSHOT")) {
        Some("snapshots" at nexus + "snapshots/")
      } else {
        Some("releases" at nexus + "releases/")
      }
    },
    credentials += Credentials(Path.userHome / ".ivy2" / ".credentials"),
    publishArtifact in Test := true
  )
}